﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="CapNhapQuyen.ascx.cs" Inherits="iShopping.Admin.UserControl.CapNhapQuyen" %>
<style type="text/css">
    .style1
    {
        width: 100%;
    }
</style>
<div id="loaitaikhoan" style="overflow: hidden; padding: 2px; margin: 6px 4px 6px 4px; border-style: solid; border-width: 1px">
    <asp:Label ID="Label1" runat="server" Text="Danh Sách Loại Tài Khoản"></asp:Label>
    <asp:DropDownList ID="ddlLoai" runat="server" Height="25px" Width="130px" 
        onselectedindexchanged="ddlLoai_SelectedIndexChanged" AutoPostBack="True" 
        >
    </asp:DropDownList>
    </div>
<!-- end loai tai khoan -->
<div id="phanquyen" 
        style="padding: 2px; margin: 6px 2px 6px 2px; border-style: Solid; border-width: 1px" >
        <p>CẬP NHẬP THÔNG TIN QUYỀN</p>
<asp:GridView ID="GRPhanQuyen" runat="server" AutoGenerateColumns="False" AllowPaging="True"
            BackColor="White" BorderColor="#CCCCCC" BorderStyle="None" BorderWidth="1px" 
            CellPadding="3" DataKeyNames="MaLoaiTK" 
            onpageindexchanging="GRPhanQuyen_PageIndexChanging" 
            onrowdeleting="GRPhanQuyen_RowDeleting" onrowediting="GRPhanQuyen_RowEditing" 
            onrowupdating="GRPhanQuyen_RowUpdating" 
            onrowcancelingedit="GRPhanQuyen_RowCancelingEdit" 
            onrowupdated="GRPhanQuyen_RowUpdated"      >
            <Columns>
                <asp:BoundField DataField="MaLoaiTK" HeaderText="Mã Loại Tài Khoản" 
                    ReadOnly="True" />
                <asp:BoundField DataField="TenLoaiTK" HeaderText="Tên Loại Tài Khoản" 
                    ReadOnly="True" />
                <asp:TemplateField HeaderText="Mã Quyền">
                  <EditItemTemplate>
                        <asp:DropDownList ID="ddlMaQuyen" runat="server">
                        </asp:DropDownList>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="lblMaQuyen" runat="server" Text='<%# Bind("MaPhanQuyen") %>'></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="TenQuyen" HeaderText="Tên Quyền" ReadOnly="True" />
                <asp:CommandField ButtonType="Image" DeleteImageUrl="~/images/Admin/delete.gif" 
                    ShowDeleteButton="True" HeaderText="Xóa" />
                <asp:CommandField ButtonType="Image" CancelImageUrl="~/images/Admin/cancel.gif" 
                    EditImageUrl="~/images/Admin/edit.gif" ShowEditButton="True" 
                    UpdateImageUrl="~/images/Admin/update.gif" CausesValidation="False" 
                    HeaderText="Cạp Nhập" />
            </Columns>
            <FooterStyle BackColor="White" ForeColor="#000066" />
            <HeaderStyle BackColor="#006699" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="White" ForeColor="#000066" HorizontalAlign="Left" />
            <RowStyle ForeColor="#000066" />
            <SelectedRowStyle BackColor="#669999" Font-Bold="True" ForeColor="White" />
          <%--  <SortedAscendingCellStyle BackColor="#F1F1F1" />
            <SortedAscendingHeaderStyle BackColor="#007DBB" />
            <SortedDescendingCellStyle BackColor="#CAC9C9" />
            <SortedDescendingHeaderStyle BackColor="#00547E" />--%>
        </asp:GridView>
</div>
<!-- end phan quyen -->

<div id="themquyenloaitaikhoan" align="center" style="border-style: solid; border-width: 1px; padding: 2px; margin: 2px">

    <table class="style1">
        <tr>
            <td align="right">
                Loại Tài Khoản</td>
            <td>
                <asp:DropDownList ID="ddlLoaiTaiKhoan" runat="server">
                </asp:DropDownList>
            </td>
        </tr>
        <tr>
            <td align="right">
                Phân Quyền</td>
            <td>
                <asp:DropDownList ID="ddlQuyen" runat="server">
                </asp:DropDownList>
            </td>
        </tr>
    </table>
  <!-- end du lieu -->
     
   <div id="them" align="center">
          <asp:Button ID="btnPhanQuyen" runat="server"  Text="Phân Quyền" 
              onclick="btnThem_Click" />
    </div>
</div>